import http from "@/utils/http";
const prefixUrl = {
  queryAllMenu: "/analysis/menu/list",
  querySiderTree: "/analysis/menu/userAuthMenu",
  create: "/analysis/menu/create",
  update: "/analysis/menu/edit",
  delete: "/analysis/menu/delete",
  export: "/analysis/menu/export", // 不存在
  import: "/analysis/menu/import", // 不存在
};
export default {
  role: {
    queryAllMenu: "POST:" + prefixUrl.queryAllMenu,
    querySiderTree: "POST:" + prefixUrl.querySiderTree,
    create: "POST:" + prefixUrl.create,
    update: "POST:" + prefixUrl.update,
    delete: "POST:" + prefixUrl.delete,
    export: "POST:" + prefixUrl.export,
    import: "POST:" + prefixUrl.import,
  },
  queryAllMenu(params = {}) {
    return http.post(prefixUrl.queryAllMenu, params);
  },
  querySiderTree(params = {}) {
    return http.post(prefixUrl.querySiderTree, params);
  },
  create(params = {}) {
    return http.post(prefixUrl.create, params);
  },
  update(params = {}) {
    return http.post(prefixUrl.update, params);
  },
  delete(params = {}) {
    return http.post(prefixUrl.delete, params);
  },
};
